﻿using System;
using Ah.Testudin.Engine.Actors;
using Ah.Testudin.Engine.Graphics.Scenes;
using Ah.Testudin.Engine.Graphics.Scenes.SceneNodes;

namespace Ah.Testudin.Engine.Events.Components
{
    public class RenderComponentCreatedEvent : ITestudinEvent
    {
        #region Properties

        public ActorId ActorId { get; private set; }

        public ISceneNode SceneNode { get; private set; }

        #endregion

        public RenderComponentCreatedEvent(
            ActorId actorId,
            ISceneNode sceneNode)
        {
            if (actorId == null)
            {
                throw new ArgumentNullException("actorId");
            }

            if (sceneNode == null)
            {
                throw new ArgumentNullException("sceneNode");
            }

            this.ActorId = actorId;

            this.SceneNode = sceneNode;
        }

        #region ITestudinEvent

        public EventType EventType { get { return EventType.RenderComponentCreated; } }

        #endregion
    }
}
